Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an option to exclude based on source names #234

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

learn-more
Copy link
Contributor

#203

This includes a testcase for both include and exclude.

@learn-more
Copy link
Contributor Author

@haberman apart from the merge conflict, anything here that should be improved?

Copy link
Member

@haberman haberman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great, just a few comments.

@@ -1940,6 +1959,8 @@ USAGE: bloaty [OPTION]... FILE... [-- BASE_FILE...]
--list-sources Show a list of available sources and exit.
--source-filter=PATTERN
Only show keys with names matching this pattern.
--not-source-filter=PATTERN
Exclude keys with names matching this pattern.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should document what happens if a name matches both --source-filter and --exclude-source-filter.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wrote a test that shows what happens, basically nothing is output other than the fact that everything is omitted.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has been added the the help text.

src/bloaty.cc Outdated Show resolved Hide resolved
@learn-more
Copy link
Contributor Author

@haberman I'd like to finish this after #264 is merged, so that I can implement this testcase with yaml2obj instead of the current c++ test. (I will remove the c++ test from this PR, and add a lit test)

@learn-more
Copy link
Contributor Author

@haberman sorry for the delay, I finally updated this.
The tests fail due to #317

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants